package org.edu.dao.impl;

import java.util.List;

import org.edu.dao.RolesSciencyDao;
import org.edu.model.RolesSciency;
import org.hibernate.SessionFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

@Repository
public class RolesSciencyDaoImpl implements RolesSciencyDao {

	@Autowired
	private SessionFactory sessionFactory;
	public RolesSciencyDaoImpl() {
	}

	@Override
	public List<RolesSciency> rolesSciencies() {
		return sessionFactory.getCurrentSession().createQuery("from RolesSciency").list();
	}

}
